@extends('admin.container')

@section('c-head')
    <script type="text/javascript">

        var PAGE_DATA = {
            REST_API: {
                // 获取热点词列表数据,搜索
                get_hotspot_list_url: "{{route('admin.hot.word.index')}}",
                del_hotspot_list_url: "{{route('admin.hot.word.batch-remove')}}",
                new_hot_url: "{{route('admin.hot.word.create')}}",
            }

        };
    </script>
@stop

@section('c-body')
    <div class="comm-title">
        <span class="title-msg">热点词设置</span>
    </div>
    <div class="comm-body">
        <div class="tab-body current1">
            <div class="supplyList-screen mt20">
                <div class="supplyList-screen-main">
                    <div class="sl-screen-box">
                        <div class="am-btn-group" style="margin-top: 22px;">
                            <a type="button" class="am-btn am-btn-success am-btn-sm " id="add_hot">
                                <span style="width:100px;display:block;">新增热点词</span>
                            </a>
                        </div>
                    </div>
                </div>
            </div>
            <!-- 表单列表 -->
            <table class="am-table am-table-striped am-table-hover am-table-centered brand-manage-tbl shopAdmin-list mt20">
                <thead>
                <tr>
                    <th style="width:5%">
                        <span style="visibility:hidden;">1</span>
                    </th>
                    <th>排序</th>
                    <th>热点词</th>
                    <th>展示位置</th>
                    <th>链接地址</th>
                    <th style="width:10%">操作</th>
                </tr>
                </thead>
                <tbody class="shopAdmin-list-body" id="hot_spotList_context">
                </tbody>
            </table>
            <div class="tool-bar-bottom clearfix">
                <div class="unit">
                    <input id="sel-all-chk" type="checkbox" class="mid" style="position: relative; top:13px;" />
                </div>
                <div class="unit">
                    <label for="sel-all-chk" style="cursor:pointer;font-weight:300;">全选</label>
                </div>
                <div class="unit">
                    <button id="del-multi-btn" type="button" class="am-btn am-btn-default am-btn-xs ml10 all-shield-btn" style="position: relative;float:left;top:5px;">删除</button>
                </div>
            </div>
            <div id="comm-paging" class="admin-paging" current-page="1"></div>
        </div>
    </div>
    <script type="text/template" id="tbl-list-templ">
        <% _.each(obj, function(item){   %>
        <tr>
            <td class="sel-chk">
                <input type="checkbox" id="<%=item.id%>" />
            </td>
            <td style="max-width: 80px;">
                <%=item.sort%>
            </td>
            <td style="max-width: 80px;">
                <%=item.name%>
            </td>
            <td style="max-width: 80px;">
                <%=item.show%>
            </td>
            <td style="max-width: 80px;">
                <%=item.link%>
            </td>
            <td style="width:15%">
                <div class="operate-btns-2 clearfix">
                    <a id="" type="button" class="edit-brand-btn am-btn am-btn-primary am-btn-xs" href="<%=item.editor_url%>" style="float:left;">编辑</a>
                    <button id="" type="button" class=" am-btn am-btn-default am-btn-xs del-hot-btn" style="float:left; margin-left: 10px;" code="<%=item.id%>" href="<%=item.dele_url%>">删除</button>
                </div>
            </td>
        </tr>
        <% }); %>
    </script>
    <script src="/assets/b2b/admin/js/pages/20.js"></script>
@stop